#define _CRT_SECURE_NO_WARNINGS
#include<vector>
using namespace std;
bool increasingTriplet(vector<int>& nums) {
    int len1 = nums[0];
    int len2 = INT_MAX;

    for (auto& num : nums) {
        if (num <= len1)
            len1 = num;
        else if (num > len1 && num <= len2)
            len2 = num;
        else
            return true;
    }
    return false;
}